gtk_widget_list_mnemonic_labels
gtk_widget_add_mnemonic_label
gtk_widget_remove_mnemonic_label
-gtk_widget_is_composited
gtk_widget_error_bell
gtk_widget_keynav_failed
gtk_widget_get_tooltip_markup
Note that the presence of an RGBA visual is no guarantee that the
window will actually appear transparent on screen. On X11, this
requires a compositing manager to be running. See
-gtk_widget_is_composited() for a way to find out if the alpha
+gdk_display_is_composited() for a way to find out if the alpha
channel will be respected.
</para>
</answer>
g_object_unref (widget);
}
-/**
- * gtk_widget_is_composited:
- * @widget: a #GtkWidget
- *
- * Whether @widget can rely on having its alpha channel
- * drawn correctly. On X11 this function returns whether a
- * compositing manager is running for @widget’s display.
- *
- * Returns: %TRUE if the widget can rely on its alpha
- * channel being drawn correctly.
- *
- * Since: 2.10
- */
-gboolean
-gtk_widget_is_composited (GtkWidget *widget)
-{
- GdkDisplay *display;
-
- g_return_val_if_fail (GTK_IS_WIDGET (widget), FALSE);
-
- display = gtk_widget_get_display (widget);
-
- return gdk_display_is_composited (display);
-}
-
/**
* _gtk_widget_propagate_screen_changed:
* @widget: a #GtkWidget
* are some limitations:
*
* For toplevel widgets this depends on the capabilities of the windowing
- * system. On X11 this has any effect only on X screens with a compositing manager
- * running. See gtk_widget_is_composited(). On Windows it should work
+ * system. On X11 this has any effect only on X displays with a compositing manager
+ * running. See gdk_display_is_composited(). On Windows it should work
* always, although setting a window’s opacity after the window has been
* shown causes it to flicker once on Windows.
*
- * For child widgets it doesn’t work if any affected widget has a native window, or
- * disables double buffering.
+ * For child widgets it doesn’t work if any affected widget has a native window.
*
* Since: 3.8
**/
GDK_AVAILABLE_IN_ALL
GtkTextDirection gtk_widget_get_default_direction (void);
-/* Compositing manager functionality */
-GDK_AVAILABLE_IN_ALL
-gboolean gtk_widget_is_composited (GtkWidget *widget);
-
/* Counterpart to gdk_window_shape_combine_region.
*/
GDK_AVAILABLE_IN_ALL
{
cairo_pattern_t *pattern;
int radius, width, height;
+ GdkDisplay *display;
/* Get the child allocation to avoid painting over the borders */
GtkWidget *child = gtk_bin_get_child (GTK_BIN (widget));
height / 2,
radius * 1.33);
- if (gdk_screen_get_rgba_visual (gtk_widget_get_screen (widget)) &&
- gtk_widget_is_composited (widget))
+ display = gtk_widget_get_display (widget);
+ if (gdk_display_is_rgba (display) &&
+ gdk_display_is_composited (display))
cairo_set_source_rgba (cr, 1.0, 1.0, 1.0, 0.0); /* transparent */
else
cairo_set_source_rgb (cr, 1.0, 1.0, 1.0); /* opaque white */